package blackeagle.ems.entities;

import blackeagle.ems.dal.DataList;

/**
 * A collection of employees.
 */
public class EmployeeCollection extends DataList<Employee, EmployeeCollection> {
    /**
     * The default 0-parameter constructor.
     */
    public EmployeeCollection(){}
    
    @Override
    public Employee getById(Integer id){
        Employee retval = null;
        
        for(Employee e : this){
            if(e.getId()==id){
                retval = e;
                break;
            }
        }
        
        return retval;
    }
}
